package it.patterns.creational.abstractfactory;

public class ConcreteFactory_Alternative implements AbstractFactory_Alternative {

	@Override
	public AbstractProduct createProduct(int type) {
		switch (type) {
		case AbstractFactory_Alternative.TYPE_A:
			return new ConcreteProductA();
		case AbstractFactory_Alternative.TYPE_B:
			return new ConcreteProductB();
		default:
			return null;
		}
	}

}
